package com.aaa.tmr.util;

import lombok.Data;
import org.springframework.boot.context.properties.ConfigurationProperties;
import org.springframework.context.annotation.PropertySource;
import org.springframework.stereotype.Component;

/**
 * @ fileName:OssProperty
 * @ description:springboot提供读取*.properties方式
 * @ author:zhz
 * @ createTime:2021/3/23 14:47
 */
@Component //交给ioc容器管理
@PropertySource("classpath:project.properties") //指定加载的配置文件路径
@ConfigurationProperties(prefix = "oss") //指定配置属性  前缀为oss
@Data
public class OssProperty {
    private String endpoint;
    private String url;
    private String accessKeyId;
    private String accessKeySecret;
    private String bucketName;
}
